/**
 * @file
 * @author  Tsin Smith <tsin.creator@gmail.com>
 *
 * @section DESCRIPTION
 *
 */

#ifndef __TSIN_RUNTIME_GAMEEVENTHANDLEWORK_HPP__
#define __TSIN_RUNTIME_GAMEEVENTHANDLEWORK_HPP__

#include <tsin/runtime/common.hpp>
#include <tsin/runtime/Work.hpp>

namespace tsin {

        static const int MAX_GAME_EVENTS = 20;

        class GameEvent;

        class RUNTIME_DLLEXPORT GameEventHandleWork : public Work {
        public:
                GameEventHandleWork();
                ~GameEventHandleWork();

                virtual void init(GameRuntime *runtime);
                virtual int run();

        private:
                GameRuntime *runtime;
                GameEvent *events[MAX_GAME_EVENTS];
                int nrEvents;
        };
}

#endif /* __TSIN_RUNTIME_GAMEEVENTHANDLEWORK_HPP__ */
